<style disabled>
    .nav .nav {
        padding-left:    2em;
    }
    article a.anchor {
        display:    none;
    }
</style>
<script src="File.js"></script>

<form class="form-inline" onsubmit="return false">
    <div class="form-group col-md-4">
        分支
        <select class="form-control" name="branch"
                data-href="?data=${scope.branches_url.split('{')[0]}">

            <option selected="${view.name === scope.default_branch}">
                <!--${view.name}-->
            </option>
        </select>
    </div>
    <div class="form-group col-md-4">
        HTTPS
        <input type="url" class="form-control"
               value="${scope.clone_url}" readonly />
    </div>
    <div class="form-group col-md-4">
        SSH
        <input type="url" class="form-control"
               value="${scope.ssh_url}" readonly />
    </div>
</form>

<div class="row">
    <nav class="col-md-4"
         data-href="?data=${ scope.contents_url.split('{')[0].slice(0, -1) }?ref=${scope.branch || scope.default_branch}"
         onupdate="${view.loadBranch}">

        <ul data-name="list" class="nav nav-pills nav-stacked">
            <li>
                <a target="_blank" href="${view.html_url}"
                   onclick="${scope['open' + view.type]}"
                   data-autofocus="${ /ReadMe\.?/i.test( view.name ) }">
                    ${view.name}
                    <i class="caret"
                       style="display: ${view.type === 'dir'  ?  ''  :  'none'}">
                    </i>
                </a>

                <ul is="TreeView" data-href="?data=${view.url}"
                    class="nav nav-pills nav-stacked">
                    <li>
                        <a target="_blank" href="${view.html_url}"
                           onclick="${scope['open' + view.type]}">
                            ${view.name}
                            <i class="caret"
                               style="display: ${view.type === 'dir'  ?  ''  :  'none'}">
                            </i>
                        </a>
                    </li>
                </ul>
            </li>
        </ul>
    </nav>
    <article class="col-md-8"></article>
</div>
